Integrand size = 23, antiderivative size = 94 \[ \int \frac {x \left (A+B x^2\right )}{\left (a+b x^2+c x^4\right )^2} \, dx=-\frac {A b-2 a B-(b B-2 A c) x^2}{2 \left (b^2-4 a c\right ) \left (a+b x^2+c x^4\right )}-\frac {(b B-2 A c) \text {arctanh}\left (\frac {b+2 c x^2}{\sqrt {b^2-4 a c}}\right )}{\left (b^2-4 a c\right )^{3/2}} \]
1/2*(-A*b+2*B*a+(-2*A*c+B*b)*x^2)/(-4*a*c+b^2)/(c*x^4+b*x^2+a)-(-2*A*c+B*b )*arctanh((2*c*x^2+b)/(-4*a*c+b^2)^(1/2))/(-4*a*c+b^2)^(3/2)
Time = 0.06 (sec) , antiderivative size = 101, normalized size of antiderivative = 1.07 \[ \int \frac {x \left (A+B x^2\right )}{\left (a+b x^2+c x^4\right )^2} \, dx=\frac {\frac {B \left (2 a+b x^2\right )-A \left (b+2 c x^2\right )}{a+b x^2+c x^4}+\frac {2 (b B-2 A c) \arctan \left (\frac {b+2 c x^2}{\sqrt {-b^2+4 a c}}\right )}{\sqrt {-b^2+4 a c}}}{2 \left (b^2-4 a c\right )} \]
((B*(2*a + b*x^2) - A*(b + 2*c*x^2))/(a + b*x^2 + c*x^4) + (2*(b*B - 2*A*c )*ArcTan[(b + 2*c*x^2)/Sqrt[-b^2 + 4*a*c]])/Sqrt[-b^2 + 4*a*c])/(2*(b^2 - 4*a*c))
Time = 0.24 (sec) , antiderivative size = 96, normalized size of antiderivative = 1.02, number of steps used = 5, number of rules used = 4, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.174, Rules used = {1576, 1159, 1083, 219}
Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.
\(\displaystyle \int \frac {x \left (A+B x^2\right )}{\left (a+b x^2+c x^4\right )^2} \, dx\) |
\(\Big \downarrow \) 1576 |
\(\displaystyle \frac {1}{2} \int \frac {B x^2+A}{\left (c x^4+b x^2+a\right )^2}dx^2\) |
\(\Big \downarrow \) 1159 |
\(\displaystyle \frac {1}{2} \left (\frac {(b B-2 A c) \int \frac {1}{c x^4+b x^2+a}dx^2}{b^2-4 a c}-\frac {-2 a B-\left (x^2 (b B-2 A c)\right )+A b}{\left (b^2-4 a c\right ) \left (a+b x^2+c x^4\right )}\right )\) |
\(\Big \downarrow \) 1083 |
\(\displaystyle \frac {1}{2} \left (-\frac {2 (b B-2 A c) \int \frac {1}{-x^4+b^2-4 a c}d\left (2 c x^2+b\right )}{b^2-4 a c}-\frac {-2 a B-\left (x^2 (b B-2 A c)\right )+A b}{\left (b^2-4 a c\right ) \left (a+b x^2+c x^4\right )}\right )\) |
\(\Big \downarrow \) 219 |
\(\displaystyle \frac {1}{2} \left (-\frac {2 (b B-2 A c) \text {arctanh}\left (\frac {b+2 c x^2}{\sqrt {b^2-4 a c}}\right )}{\left (b^2-4 a c\right )^{3/2}}-\frac {-2 a B-\left (x^2 (b B-2 A c)\right )+A b}{\left (b^2-4 a c\right ) \left (a+b x^2+c x^4\right )}\right )\) |
(-((A*b - 2*a*B - (b*B - 2*A*c)*x^2)/((b^2 - 4*a*c)*(a + b*x^2 + c*x^4))) - (2*(b*B - 2*A*c)*ArcTanh[(b + 2*c*x^2)/Sqrt[b^2 - 4*a*c]])/(b^2 - 4*a*c) ^(3/2))/2
3.2.15.3.1 Defintions of rubi rules used
Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(1/(Rt[a, 2]*Rt[-b, 2]))* ArcTanh[Rt[-b, 2]*(x/Rt[a, 2])], x] /; FreeQ[{a, b}, x] && NegQ[a/b] && (Gt Q[a, 0] || LtQ[b, 0])
Int[((a_) + (b_.)*(x_) + (c_.)*(x_)^2)^(-1), x_Symbol] :> Simp[-2 Subst[I nt[1/Simp[b^2 - 4*a*c - x^2, x], x], x, b + 2*c*x], x] /; FreeQ[{a, b, c}, x]
Int[((d_.) + (e_.)*(x_))*((a_.) + (b_.)*(x_) + (c_.)*(x_)^2)^(p_), x_Symbol ] :> Simp[((b*d - 2*a*e + (2*c*d - b*e)*x)/((p + 1)*(b^2 - 4*a*c)))*(a + b* x + c*x^2)^(p + 1), x] - Simp[(2*p + 3)*((2*c*d - b*e)/((p + 1)*(b^2 - 4*a* c))) Int[(a + b*x + c*x^2)^(p + 1), x], x] /; FreeQ[{a, b, c, d, e}, x] & & LtQ[p, -1] && NeQ[p, -3/2]
Int[(x_)*((d_) + (e_.)*(x_)^2)^(q_.)*((a_) + (b_.)*(x_)^2 + (c_.)*(x_)^4)^( p_.), x_Symbol] :> Simp[1/2 Subst[Int[(d + e*x)^q*(a + b*x + c*x^2)^p, x] , x, x^2], x] /; FreeQ[{a, b, c, d, e, p, q}, x]
Time = 0.10 (sec) , antiderivative size = 95, normalized size of antiderivative = 1.01
method | result | size |
default | \(\frac {\left (2 A c -B b \right ) x^{2}+A b -2 B a}{2 \left (4 a c -b^{2}\right ) \left (c \,x^{4}+b \,x^{2}+a \right )}+\frac {\left (2 A c -B b \right ) \arctan \left (\frac {2 c \,x^{2}+b}{\sqrt {4 a c -b^{2}}}\right )}{\left (4 a c -b^{2}\right )^{\frac {3}{2}}}\) | \(95\) |
risch | \(\frac {\frac {\left (2 A c -B b \right ) x^{2}}{8 a c -2 b^{2}}+\frac {A b -2 B a}{8 a c -2 b^{2}}}{c \,x^{4}+b \,x^{2}+a}+\frac {\ln \left (\left (\left (-4 a c +b^{2}\right )^{\frac {3}{2}}+4 a b c -b^{3}\right ) x^{2}+8 c \,a^{2}-2 b^{2} a \right ) A c}{\left (-4 a c +b^{2}\right )^{\frac {3}{2}}}-\frac {\ln \left (\left (\left (-4 a c +b^{2}\right )^{\frac {3}{2}}+4 a b c -b^{3}\right ) x^{2}+8 c \,a^{2}-2 b^{2} a \right ) B b}{2 \left (-4 a c +b^{2}\right )^{\frac {3}{2}}}-\frac {\ln \left (\left (\left (-4 a c +b^{2}\right )^{\frac {3}{2}}-4 a b c +b^{3}\right ) x^{2}-8 c \,a^{2}+2 b^{2} a \right ) A c}{\left (-4 a c +b^{2}\right )^{\frac {3}{2}}}+\frac {\ln \left (\left (\left (-4 a c +b^{2}\right )^{\frac {3}{2}}-4 a b c +b^{3}\right ) x^{2}-8 c \,a^{2}+2 b^{2} a \right ) B b}{2 \left (-4 a c +b^{2}\right )^{\frac {3}{2}}}\) | \(273\) |
1/2*((2*A*c-B*b)*x^2+A*b-2*B*a)/(4*a*c-b^2)/(c*x^4+b*x^2+a)+(2*A*c-B*b)/(4 *a*c-b^2)^(3/2)*arctan((2*c*x^2+b)/(4*a*c-b^2)^(1/2))
Leaf count of result is larger than twice the leaf count of optimal. 225 vs. \(2 (88) = 176\).
Time = 0.26 (sec) , antiderivative size = 474, normalized size of antiderivative = 5.04 \[ \int \frac {x \left (A+B x^2\right )}{\left (a+b x^2+c x^4\right )^2} \, dx=\left [\frac {2 \, B a b^{2} - A b^{3} + {\left (B b^{3} + 8 \, A a c^{2} - 2 \, {\left (2 \, B a b + A b^{2}\right )} c\right )} x^{2} + {\left ({\left (B b c - 2 \, A c^{2}\right )} x^{4} + B a b - 2 \, A a c + {\left (B b^{2} - 2 \, A b c\right )} x^{2}\right )} \sqrt {b^{2} - 4 \, a c} \log \left (\frac {2 \, c^{2} x^{4} + 2 \, b c x^{2} + b^{2} - 2 \, a c - {\left (2 \, c x^{2} + b\right )} \sqrt {b^{2} - 4 \, a c}}{c x^{4} + b x^{2} + a}\right ) - 4 \, {\left (2 \, B a^{2} - A a b\right )} c}{2 \, {\left (a b^{4} - 8 \, a^{2} b^{2} c + 16 \, a^{3} c^{2} + {\left (b^{4} c - 8 \, a b^{2} c^{2} + 16 \, a^{2} c^{3}\right )} x^{4} + {\left (b^{5} - 8 \, a b^{3} c + 16 \, a^{2} b c^{2}\right )} x^{2}\right )}}, \frac {2 \, B a b^{2} - A b^{3} + {\left (B b^{3} + 8 \, A a c^{2} - 2 \, {\left (2 \, B a b + A b^{2}\right )} c\right )} x^{2} - 2 \, {\left ({\left (B b c - 2 \, A c^{2}\right )} x^{4} + B a b - 2 \, A a c + {\left (B b^{2} - 2 \, A b c\right )} x^{2}\right )} \sqrt {-b^{2} + 4 \, a c} \arctan \left (-\frac {{\left (2 \, c x^{2} + b\right )} \sqrt {-b^{2} + 4 \, a c}}{b^{2} - 4 \, a c}\right ) - 4 \, {\left (2 \, B a^{2} - A a b\right )} c}{2 \, {\left (a b^{4} - 8 \, a^{2} b^{2} c + 16 \, a^{3} c^{2} + {\left (b^{4} c - 8 \, a b^{2} c^{2} + 16 \, a^{2} c^{3}\right )} x^{4} + {\left (b^{5} - 8 \, a b^{3} c + 16 \, a^{2} b c^{2}\right )} x^{2}\right )}}\right ] \]
[1/2*(2*B*a*b^2 - A*b^3 + (B*b^3 + 8*A*a*c^2 - 2*(2*B*a*b + A*b^2)*c)*x^2 + ((B*b*c - 2*A*c^2)*x^4 + B*a*b - 2*A*a*c + (B*b^2 - 2*A*b*c)*x^2)*sqrt(b ^2 - 4*a*c)*log((2*c^2*x^4 + 2*b*c*x^2 + b^2 - 2*a*c - (2*c*x^2 + b)*sqrt( b^2 - 4*a*c))/(c*x^4 + b*x^2 + a)) - 4*(2*B*a^2 - A*a*b)*c)/(a*b^4 - 8*a^2 *b^2*c + 16*a^3*c^2 + (b^4*c - 8*a*b^2*c^2 + 16*a^2*c^3)*x^4 + (b^5 - 8*a* b^3*c + 16*a^2*b*c^2)*x^2), 1/2*(2*B*a*b^2 - A*b^3 + (B*b^3 + 8*A*a*c^2 - 2*(2*B*a*b + A*b^2)*c)*x^2 - 2*((B*b*c - 2*A*c^2)*x^4 + B*a*b - 2*A*a*c + (B*b^2 - 2*A*b*c)*x^2)*sqrt(-b^2 + 4*a*c)*arctan(-(2*c*x^2 + b)*sqrt(-b^2 + 4*a*c)/(b^2 - 4*a*c)) - 4*(2*B*a^2 - A*a*b)*c)/(a*b^4 - 8*a^2*b^2*c + 16 *a^3*c^2 + (b^4*c - 8*a*b^2*c^2 + 16*a^2*c^3)*x^4 + (b^5 - 8*a*b^3*c + 16* a^2*b*c^2)*x^2)]
Leaf count of result is larger than twice the leaf count of optimal. 374 vs. \(2 (83) = 166\).
Time = 2.28 (sec) , antiderivative size = 374, normalized size of antiderivative = 3.98 \[ \int \frac {x \left (A+B x^2\right )}{\left (a+b x^2+c x^4\right )^2} \, dx=\frac {\sqrt {- \frac {1}{\left (4 a c - b^{2}\right )^{3}}} \left (- 2 A c + B b\right ) \log {\left (x^{2} + \frac {- 2 A b c + B b^{2} - 16 a^{2} c^{2} \sqrt {- \frac {1}{\left (4 a c - b^{2}\right )^{3}}} \left (- 2 A c + B b\right ) + 8 a b^{2} c \sqrt {- \frac {1}{\left (4 a c - b^{2}\right )^{3}}} \left (- 2 A c + B b\right ) - b^{4} \sqrt {- \frac {1}{\left (4 a c - b^{2}\right )^{3}}} \left (- 2 A c + B b\right )}{- 4 A c^{2} + 2 B b c} \right )}}{2} - \frac {\sqrt {- \frac {1}{\left (4 a c - b^{2}\right )^{3}}} \left (- 2 A c + B b\right ) \log {\left (x^{2} + \frac {- 2 A b c + B b^{2} + 16 a^{2} c^{2} \sqrt {- \frac {1}{\left (4 a c - b^{2}\right )^{3}}} \left (- 2 A c + B b\right ) - 8 a b^{2} c \sqrt {- \frac {1}{\left (4 a c - b^{2}\right )^{3}}} \left (- 2 A c + B b\right ) + b^{4} \sqrt {- \frac {1}{\left (4 a c - b^{2}\right )^{3}}} \left (- 2 A c + B b\right )}{- 4 A c^{2} + 2 B b c} \right )}}{2} + \frac {A b - 2 B a + x^{2} \cdot \left (2 A c - B b\right )}{8 a^{2} c - 2 a b^{2} + x^{4} \cdot \left (8 a c^{2} - 2 b^{2} c\right ) + x^{2} \cdot \left (8 a b c - 2 b^{3}\right )} \]
sqrt(-1/(4*a*c - b**2)**3)*(-2*A*c + B*b)*log(x**2 + (-2*A*b*c + B*b**2 - 16*a**2*c**2*sqrt(-1/(4*a*c - b**2)**3)*(-2*A*c + B*b) + 8*a*b**2*c*sqrt(- 1/(4*a*c - b**2)**3)*(-2*A*c + B*b) - b**4*sqrt(-1/(4*a*c - b**2)**3)*(-2* A*c + B*b))/(-4*A*c**2 + 2*B*b*c))/2 - sqrt(-1/(4*a*c - b**2)**3)*(-2*A*c + B*b)*log(x**2 + (-2*A*b*c + B*b**2 + 16*a**2*c**2*sqrt(-1/(4*a*c - b**2) **3)*(-2*A*c + B*b) - 8*a*b**2*c*sqrt(-1/(4*a*c - b**2)**3)*(-2*A*c + B*b) + b**4*sqrt(-1/(4*a*c - b**2)**3)*(-2*A*c + B*b))/(-4*A*c**2 + 2*B*b*c))/ 2 + (A*b - 2*B*a + x**2*(2*A*c - B*b))/(8*a**2*c - 2*a*b**2 + x**4*(8*a*c* *2 - 2*b**2*c) + x**2*(8*a*b*c - 2*b**3))
Exception generated. \[ \int \frac {x \left (A+B x^2\right )}{\left (a+b x^2+c x^4\right )^2} \, dx=\text {Exception raised: ValueError} \]
Exception raised: ValueError >> Computation failed since Maxima requested additional constraints; using the 'assume' command before evaluation *may* help (example of legal syntax is 'assume(4*a*c-b^2>0)', see `assume?` for more deta
Time = 0.56 (sec) , antiderivative size = 102, normalized size of antiderivative = 1.09 \[ \int \frac {x \left (A+B x^2\right )}{\left (a+b x^2+c x^4\right )^2} \, dx=\frac {{\left (B b - 2 \, A c\right )} \arctan \left (\frac {2 \, c x^{2} + b}{\sqrt {-b^{2} + 4 \, a c}}\right )}{{\left (b^{2} - 4 \, a c\right )} \sqrt {-b^{2} + 4 \, a c}} + \frac {B b x^{2} - 2 \, A c x^{2} + 2 \, B a - A b}{2 \, {\left (c x^{4} + b x^{2} + a\right )} {\left (b^{2} - 4 \, a c\right )}} \]
(B*b - 2*A*c)*arctan((2*c*x^2 + b)/sqrt(-b^2 + 4*a*c))/((b^2 - 4*a*c)*sqrt (-b^2 + 4*a*c)) + 1/2*(B*b*x^2 - 2*A*c*x^2 + 2*B*a - A*b)/((c*x^4 + b*x^2 + a)*(b^2 - 4*a*c))
Time = 7.67 (sec) , antiderivative size = 264, normalized size of antiderivative = 2.81 \[ \int \frac {x \left (A+B x^2\right )}{\left (a+b x^2+c x^4\right )^2} \, dx=\frac {\frac {A\,b-2\,B\,a}{2\,\left (4\,a\,c-b^2\right )}+\frac {x^2\,\left (2\,A\,c-B\,b\right )}{2\,\left (4\,a\,c-b^2\right )}}{c\,x^4+b\,x^2+a}+\frac {\mathrm {atan}\left (\frac {\left (x^2\,\left (\frac {\left (2\,A\,c-B\,b\right )\,\left (2\,A\,c^3-B\,b\,c^2\right )}{a\,{\left (4\,a\,c-b^2\right )}^{7/2}}+\frac {\left (2\,b^3\,c^2-8\,a\,b\,c^3\right )\,{\left (2\,A\,c-B\,b\right )}^2\,\left (b^3-4\,a\,b\,c\right )}{2\,a\,{\left (4\,a\,c-b^2\right )}^{13/2}}\right )-\frac {2\,c^2\,{\left (2\,A\,c-B\,b\right )}^2\,\left (b^3-4\,a\,b\,c\right )}{{\left (4\,a\,c-b^2\right )}^{11/2}}\right )\,{\left (4\,a\,c-b^2\right )}^4}{8\,A^2\,c^4-8\,A\,B\,b\,c^3+2\,B^2\,b^2\,c^2}\right )\,\left (2\,A\,c-B\,b\right )}{{\left (4\,a\,c-b^2\right )}^{3/2}} \]
((A*b - 2*B*a)/(2*(4*a*c - b^2)) + (x^2*(2*A*c - B*b))/(2*(4*a*c - b^2)))/ (a + b*x^2 + c*x^4) + (atan(((x^2*(((2*A*c - B*b)*(2*A*c^3 - B*b*c^2))/(a* (4*a*c - b^2)^(7/2)) + ((2*b^3*c^2 - 8*a*b*c^3)*(2*A*c - B*b)^2*(b^3 - 4*a *b*c))/(2*a*(4*a*c - b^2)^(13/2))) - (2*c^2*(2*A*c - B*b)^2*(b^3 - 4*a*b*c ))/(4*a*c - b^2)^(11/2))*(4*a*c - b^2)^4)/(8*A^2*c^4 + 2*B^2*b^2*c^2 - 8*A *B*b*c^3))*(2*A*c - B*b))/(4*a*c - b^2)^(3/2)